<!DOCTYPE HTML>
<html lang="en" >
    
    <head>
        
        <meta charset="UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <title>语句 | H5学习笔记</title>
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
        <meta name="description" content="">
        <meta name="generator" content="GitBook 2.6.7">
        
        
        <meta name="HandheldFriendly" content="true"/>
        <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
        <meta name="apple-mobile-web-app-capable" content="yes">
        <meta name="apple-mobile-web-app-status-bar-style" content="black">
        <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../../gitbook/images/apple-touch-icon-precomposed-152.png">
        <link rel="shortcut icon" href="../../gitbook/images/favicon.ico" type="image/x-icon">
        
    <link rel="stylesheet" href="../../gitbook/style.css">
    
        
        <link rel="stylesheet" href="../../gitbook/plugins/gitbook-plugin-highlight/website.css">
        
    
        
        <link rel="stylesheet" href="../../gitbook/plugins/gitbook-plugin-search/search.css">
        
    
        
        <link rel="stylesheet" href="../../gitbook/plugins/gitbook-plugin-fontsettings/website.css">
        
    
    

        
    
    
    <link rel="next" href="../../javascript/Javascript基础/系统自带的常用函数.html" />
    
    
    <link rel="prev" href="../../javascript/Javascript基础/运算符.html" />
    

        
    </head>
    <body>
        
        
    <div class="book"
        data-level="3.1.8"
        data-chapter-title="语句"
        data-filepath="javascript/Javascript基础/语句.md"
        data-basepath="../.."
        data-revision="Sun Jul 23 2017 22:35:00 GMT+0800 (中国标准时间)"
        data-innerlanguage="">
    

<div class="book-summary">
    <nav role="navigation">
        <ul class="summary">
            
            
            
            

            

            
    
        <li class="chapter " data-level="0" data-path="index.html">
            
                
                    <a href="../../index.html">
                
                        <i class="fa fa-check"></i>
                        
                        前言
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="1" data-path="Html/html.html">
            
                
                    <a href="../../Html/html.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.</b>
                        
                        Html
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.1" data-path="Html/基本标签.html">
            
                
                    <a href="../../Html/基本标签.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.1.</b>
                        
                        基本标签
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="1.2" data-path="Html/表单元素.html">
            
                
                    <a href="../../Html/表单元素.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.2.</b>
                        
                        表单元素
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="1.3" data-path="Html/其他标签.html">
            
                
                    <a href="../../Html/其他标签.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.3.</b>
                        
                        其他标签
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="1.4" data-path="Html/标签类型与特性.html">
            
                
                    <a href="../../Html/标签类型与特性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.4.</b>
                        
                        标签类型与特性
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="1.5" data-path="Html/HTML5新元素.html">
            
                
                    <a href="../../Html/HTML5新元素.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>1.5.</b>
                        
                        HTML5新元素
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2" >
            
            <span><b>2.</b> CSS</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.1" data-path="CSS/css语法.html">
            
                
                    <a href="../../CSS/css语法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.1.</b>
                        
                        语法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2" >
            
            <span><b>2.2.</b> 选择器</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.2.1" data-path="CSS/选择器/1.通配选择符.html">
            
                
                    <a href="../../CSS/选择器/1.通配选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.1.</b>
                        
                        通配选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.2" data-path="CSS/选择器/2.元素选择符.html">
            
                
                    <a href="../../CSS/选择器/2.元素选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.2.</b>
                        
                        元素选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.3" data-path="CSS/选择器/3.群组选择符.html">
            
                
                    <a href="../../CSS/选择器/3.群组选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.3.</b>
                        
                        群组选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.4" data-path="CSS/选择器/4.关系选择符.html">
            
                
                    <a href="../../CSS/选择器/4.关系选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.4.</b>
                        
                        关系选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.5" data-path="CSS/选择器/属性选择符.html">
            
                
                    <a href="../../CSS/选择器/属性选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.5.</b>
                        
                        属性选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.6" data-path="CSS/选择器/伪对象选择符.html">
            
                
                    <a href="../../CSS/选择器/伪对象选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.6.</b>
                        
                        伪对象选择符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.2.7" data-path="CSS/选择器/伪类选择符.html">
            
                
                    <a href="../../CSS/选择器/伪类选择符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.2.7.</b>
                        
                        伪类选择符
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.3" >
            
            <span><b>2.3.</b> 字体样式</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.3.1" data-path="CSS/字体样式/字体样式1.html">
            
                
                    <a href="../../CSS/字体样式/字体样式1.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.3.1.</b>
                        
                        字体样式
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.3.2" data-path="CSS/字体样式/text-shadow文字阴影.html">
            
                
                    <a href="../../CSS/字体样式/text-shadow文字阴影.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.3.2.</b>
                        
                        text-shadow(文字阴影)
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.4" >
            
            <span><b>2.4.</b> 元素样式</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.4.1" data-path="CSS/元素样式/margin外边距.html">
            
                
                    <a href="../../CSS/元素样式/margin外边距.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.4.1.</b>
                        
                        margin(外边距)
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.4.2" data-path="CSS/元素样式/盒子模型.html">
            
                
                    <a href="../../CSS/元素样式/盒子模型.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.4.2.</b>
                        
                        盒子模型
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.4.3" data-path="CSS/元素样式/宽高透明度.html">
            
                
                    <a href="../../CSS/元素样式/宽高透明度.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.4.3.</b>
                        
                        宽高透明度
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.5" >
            
            <span><b>2.5.</b> 边框样式</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.5.1" data-path="CSS/边框样式/边框样式1.html">
            
                
                    <a href="../../CSS/边框样式/边框样式1.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.5.1.</b>
                        
                        边框样式
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.5.2" data-path="CSS/边框样式/圆角效果.html">
            
                
                    <a href="../../CSS/边框样式/圆角效果.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.5.2.</b>
                        
                        圆角效果
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.5.3" data-path="CSS/边框样式/边框图片.html">
            
                
                    <a href="../../CSS/边框样式/边框图片.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.5.3.</b>
                        
                        边框图片
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.5.4" data-path="CSS/边框样式/盒子阴影.html">
            
                
                    <a href="../../CSS/边框样式/盒子阴影.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.5.4.</b>
                        
                        盒子阴影
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.6" >
            
            <span><b>2.6.</b> 段落样式</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.6.1" data-path="CSS/段落样式/段落样式.html">
            
                
                    <a href="../../CSS/段落样式/段落样式.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.6.1.</b>
                        
                        段落样式
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.6.2" data-path="CSS/段落样式/文字溢出.html">
            
                
                    <a href="../../CSS/段落样式/文字溢出.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.6.2.</b>
                        
                        文字溢出
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.7" >
            
            <span><b>2.7.</b> 背景样式</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.7.1" data-path="CSS/背景样式/背景样式.html">
            
                
                    <a href="../../CSS/背景样式/背景样式.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.7.1.</b>
                        
                        背景样式
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.8" >
            
            <span><b>2.8.</b> 网页布局</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.8.1" data-path="CSS/网页布局/2.两列式布局.html">
            
                
                    <a href="../../CSS/网页布局/2.两列式布局.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.8.1.</b>
                        
                        两列式布局
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.8.2" data-path="CSS/网页布局/解决行内块元素之间间距.html">
            
                
                    <a href="../../CSS/网页布局/解决行内块元素之间间距.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.8.2.</b>
                        
                        解决行内块元素之间间距
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.9" data-path="CSS/动画/动画属性概述.html">
            
                
                    <a href="../../CSS/动画/动画属性概述.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.9.</b>
                        
                        动画
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.9.1" data-path="CSS/动画/transform属性.html">
            
                
                    <a href="../../CSS/动画/transform属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.9.1.</b>
                        
                        transform属性(变换)
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.9.2" data-path="CSS/动画/translation属性.html">
            
                
                    <a href="../../CSS/动画/translation属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.9.2.</b>
                        
                        translation属性(过渡)
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.9.3" data-path="CSS/动画/Animation动画.html">
            
                
                    <a href="../../CSS/动画/Animation动画.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.9.3.</b>
                        
                        Animation动画
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.10" data-path="CSS/3D相关属性/3D相关属性.html">
            
                
                    <a href="../../CSS/3D相关属性/3D相关属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.10.</b>
                        
                        3D相关属性
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.10.1" data-path="CSS/3D相关属性/网页中的3D坐标系.html">
            
                
                    <a href="../../CSS/3D相关属性/网页中的3D坐标系.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.10.1.</b>
                        
                        网页中的3D坐标系
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.10.2" data-path="CSS/3D相关属性/正方体.html">
            
                
                    <a href="../../CSS/3D相关属性/正方体.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.10.2.</b>
                        
                        正方体
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.10.3" data-path="CSS/3D相关属性/反转卡牌.html">
            
                
                    <a href="../../CSS/3D相关属性/反转卡牌.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.10.3.</b>
                        
                        反转卡牌
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.10.4" data-path="CSS/3D相关属性/图片的旋转木马效果.html">
            
                
                    <a href="../../CSS/3D相关属性/图片的旋转木马效果.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.10.4.</b>
                        
                        图片的旋转木马效果
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.11" data-path="CSS/Sass的使用.html">
            
            <span><b>2.11.</b> Sass的使用</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.11.1" data-path="CSS/Sass的使用/特色与语法.html">
            
                
                    <a href="../../CSS/Sass的使用/特色与语法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.11.1.</b>
                        
                        特色与语法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.11.2" data-path="CSS/Sass的使用/Sass的使用.html">
            
                
                    <a href="../../CSS/Sass的使用/Sass的使用.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.11.2.</b>
                        
                        Sass的使用
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="2.12" >
            
            <span><b>2.12.</b> 重要属性单析</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="2.12.1" data-path="CSS/重要属性单析/1.vertical-align属性.html">
            
                
                    <a href="../../CSS/重要属性单析/1.vertical-align属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.12.1.</b>
                        
                        vertical-align属性
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.12.2" data-path="CSS/重要属性单析/2.cursor.html">
            
                
                    <a href="../../CSS/重要属性单析/2.cursor.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.12.2.</b>
                        
                        cursor
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="2.12.3" data-path="CSS/重要属性单析/filter滤镜.html">
            
                
                    <a href="../../CSS/重要属性单析/filter滤镜.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>2.12.3.</b>
                        
                        filter滤镜
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3" data-path="javascript/javascript介绍.html">
            
                
                    <a href="../../javascript/javascript介绍.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.</b>
                        
                        Javascript
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.1" >
            
            <span><b>3.1.</b> Javascript基础</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.1.1" data-path="javascript/Javascript基础/语法.html">
            
                
                    <a href="../../javascript/Javascript基础/语法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.1.</b>
                        
                        javascript语法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.2" data-path="javascript/Javascript基础/基本变量.html">
            
                
                    <a href="../../javascript/Javascript基础/基本变量.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.2.</b>
                        
                        基本变量
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.3" data-path="javascript/Javascript基础/复杂变量.html">
            
                
                    <a href="../../javascript/Javascript基础/复杂变量.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.3.</b>
                        
                        复杂变量
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.4" data-path="javascript/Javascript基础/类型的转换.html">
            
                
                    <a href="../../javascript/Javascript基础/类型的转换.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.4.</b>
                        
                        类型的转换
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.5" data-path="javascript/Javascript基础/判断变量的类型.html">
            
                
                    <a href="../../javascript/Javascript基础/判断变量的类型.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.5.</b>
                        
                        判断变量的类型
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.6" data-path="javascript/Javascript基础/函数.html">
            
                
                    <a href="../../javascript/Javascript基础/函数.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.6.</b>
                        
                        函数
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.7" data-path="javascript/Javascript基础/运算符.html">
            
                
                    <a href="../../javascript/Javascript基础/运算符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.7.</b>
                        
                        运算符
                    </a>
            
            
        </li>
    
        <li class="chapter active" data-level="3.1.8" data-path="javascript/Javascript基础/语句.html">
            
                
                    <a href="../../javascript/Javascript基础/语句.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.8.</b>
                        
                        语句
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.9" data-path="javascript/Javascript基础/系统自带的常用函数.html">
            
                
                    <a href="../../javascript/Javascript基础/系统自带的常用函数.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.9.</b>
                        
                        系统自带的常用函数
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.10" data-path="javascript/Javascript基础/作用域.html">
            
                
                    <a href="../../javascript/Javascript基础/作用域.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.10.</b>
                        
                        作用域
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.11" data-path="javascript/Javascript基础/垃圾收集.html">
            
                
                    <a href="../../javascript/Javascript基础/垃圾收集.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.11.</b>
                        
                        垃圾收集
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.12" >
            
            <span><b>3.1.12.</b> 引用类型</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.1.12.1" data-path="javascript/Javascript基础/引用类型/Array类型操作方法.html">
            
                
                    <a href="../../javascript/Javascript基础/引用类型/Array类型操作方法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.12.1.</b>
                        
                        Array类型操作方法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.12.2" data-path="javascript/Javascript基础/引用类型/Array类型操作方法2.html">
            
                
                    <a href="../../javascript/Javascript基础/引用类型/Array类型操作方法2.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.12.2.</b>
                        
                        Array类型操作方法2
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.1.13" data-path="javascript/对象/创建对象.html">
            
                
                    <a href="../../javascript/对象/创建对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.13.</b>
                        
                        创建对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.14" data-path="javascript/对象/Object对象的属性.html">
            
                
                    <a href="../../javascript/对象/Object对象的属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.14.</b>
                        
                        Object对象的属性
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.15" data-path="javascript/对象/函数的属性方法.html">
            
                
                    <a href="../../javascript/对象/函数的属性方法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.15.</b>
                        
                        函数的属性方法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.16" data-path="javascript/对象/使用对象.html">
            
                
                    <a href="../../javascript/对象/使用对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.16.</b>
                        
                        使用对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.17" data-path="javascript/对象/对象的继承.html">
            
                
                    <a href="../../javascript/对象/对象的继承.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.17.</b>
                        
                        对象的继承
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.18" >
            
            <span><b>3.1.18.</b> 内置对象</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.1.18.1" data-path="javascript/对象/内置对象/Array对象.html">
            
                
                    <a href="../../javascript/对象/内置对象/Array对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.18.1.</b>
                        
                        Array对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.18.2" data-path="javascript/对象/内置对象/Array对象拓展.html">
            
                
                    <a href="../../javascript/对象/内置对象/Array对象拓展.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.18.2.</b>
                        
                        Array对象拓展
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.18.3" data-path="javascript/对象/内置对象/String对象.html">
            
                
                    <a href="../../javascript/对象/内置对象/String对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.18.3.</b>
                        
                        String对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.18.4" data-path="javascript/对象/内置对象/Math对象.html">
            
                
                    <a href="../../javascript/对象/内置对象/Math对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.18.4.</b>
                        
                        Math对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.1.18.5" data-path="javascript/对象/内置对象/Date对象.html">
            
                
                    <a href="../../javascript/对象/内置对象/Date对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.1.18.5.</b>
                        
                        Date对象
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.2" >
            
            <span><b>3.2.</b> [BOM对象]    ()</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.2.1" data-path="javascript/BOM对象/Window对象.html">
            
                
                    <a href="../../javascript/BOM对象/Window对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.2.1.</b>
                        
                        Window对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.2.2" data-path="javascript/BOM对象/Location对象.html">
            
                
                    <a href="../../javascript/BOM对象/Location对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.2.2.</b>
                        
                        Location对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.2.3" data-path="javascript/BOM对象/Navigator对象.html">
            
                
                    <a href="../../javascript/BOM对象/Navigator对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.2.3.</b>
                        
                        Navigator对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.2.4" data-path="javascript/BOM对象/history对象.html">
            
                
                    <a href="../../javascript/BOM对象/history对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.2.4.</b>
                        
                        history对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.2.5" data-path="javascript/BOM对象/关于元素的尺寸.html">
            
                
                    <a href="../../javascript/BOM对象/关于元素的尺寸.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.2.5.</b>
                        
                        关于元素的尺寸
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.3" data-path="javascript/DOM对象/DOM概述.html">
            
                
                    <a href="../../javascript/DOM对象/DOM概述.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.</b>
                        
                        DOM对象
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.3.1" data-path="javascript/DOM对象/Node类型.html">
            
                
                    <a href="../../javascript/DOM对象/Node类型.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.1.</b>
                        
                        Node类型
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.3.2" data-path="javascript/DOM对象/Document类型.html">
            
                
                    <a href="../../javascript/DOM对象/Document类型.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.2.</b>
                        
                        Document类型
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.3.3" data-path="javascript/DOM对象/Element类型.html">
            
                
                    <a href="../../javascript/DOM对象/Element类型.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.3.</b>
                        
                        Element类型
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.3.4" data-path="javascript/DOM对象/选择符API.html">
            
                
                    <a href="../../javascript/DOM对象/选择符API.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.4.</b>
                        
                        选择符API
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.3.5" data-path="javascript/DOM对象/元素遍历.html">
            
                
                    <a href="../../javascript/DOM对象/元素遍历.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.5.</b>
                        
                        元素遍历
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.3.6" data-path="javascript/DOM对象/HTML5.html">
            
                
                    <a href="../../javascript/DOM对象/HTML5.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.3.6.</b>
                        
                        HTML5
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.4" >
            
            <span><b>3.4.</b> 事件</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.4.1" data-path="javascript/事件/事件.html">
            
                
                    <a href="../../javascript/事件/事件.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.4.1.</b>
                        
                        事件
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.4.2" data-path="javascript/事件/事件流.html">
            
                
                    <a href="../../javascript/事件/事件流.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.4.2.</b>
                        
                        事件流
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.4.3" data-path="javascript/事件/HTML事件处理程序.html">
            
                
                    <a href="../../javascript/事件/HTML事件处理程序.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.4.3.</b>
                        
                        HTML事件处理程序
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.5" data-path="javascript/正则表达式/正则表达式的定义.html">
            
                
                    <a href="../../javascript/正则表达式/正则表达式的定义.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.5.</b>
                        
                        正则表达式
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.6" data-path="javascript/Ajax/ajax基础.html">
            
                
                    <a href="../../javascript/Ajax/ajax基础.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.6.</b>
                        
                        Ajax
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.7" >
            
            <span><b>3.7.</b> 拓展</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.7.1" data-path="javascript/拓展/void运算符.html">
            
                
                    <a href="../../javascript/拓展/void运算符.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.7.1.</b>
                        
                        void运算符
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.7.2" data-path="javascript/拓展/懒加载.html">
            
                
                    <a href="../../javascript/拓展/懒加载.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.7.2.</b>
                        
                        懒加载
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="3.8" >
            
            <span><b>3.8.</b> Javascript问题</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="3.8.1" data-path="javascript/Javascript问题/第一天问题总结.html">
            
                
                    <a href="../../javascript/Javascript问题/第一天问题总结.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.1.</b>
                        
                        第一天问题总结
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.2" data-path="javascript/Javascript问题/NaN属性.html">
            
                
                    <a href="../../javascript/Javascript问题/NaN属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.2.</b>
                        
                        NaN属性
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.3" data-path="javascript/Javascript问题/for循环.html">
            
                
                    <a href="../../javascript/Javascript问题/for循环.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.3.</b>
                        
                        for循环
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.4" data-path="javascript/Javascript问题/获取标签问题.html">
            
                
                    <a href="../../javascript/Javascript问题/获取标签问题.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.4.</b>
                        
                        获取标签问题
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.5" data-path="javascript/Javascript问题/JS闭包导致循环给按钮添加事件时总是执行最后一个.html">
            
                
                    <a href="../../javascript/Javascript问题/JS闭包导致循环给按钮添加事件时总是执行最后一个.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.5.</b>
                        
                        JS导致循环给按钮添加事件时总是执行最后一个
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.6" data-path="javascript/Javascript问题/let语句.html">
            
                
                    <a href="../../javascript/Javascript问题/let语句.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.6.</b>
                        
                        let语句
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.7" data-path="javascript/Javascript问题/this指向问题.html">
            
                
                    <a href="../../javascript/Javascript问题/this指向问题.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.7.</b>
                        
                        this指向问题
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.8" data-path="javascript/Javascript问题/Html中data-属性的获取.html">
            
                
                    <a href="../../javascript/Javascript问题/Html中data-属性的获取.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.8.</b>
                        
                        Html中data-属性的获取
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="3.8.9" data-path="javascript/Javascript问题/表达式与语句的区别.html">
            
                
                    <a href="../../javascript/Javascript问题/表达式与语句的区别.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>3.8.9.</b>
                        
                        表达式与语句的区别
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="4" >
            
            <span><b>4.</b> jquery</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="4.1" >
            
            <span><b>4.1.</b> 选择器</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="4.1.1" data-path="jquery/选择器/表单.html">
            
                
                    <a href="../../jquery/选择器/表单.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.1.1.</b>
                        
                        表单
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.1.2" data-path="jquery/选择器/基本筛选.html">
            
                
                    <a href="../../jquery/选择器/基本筛选.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.1.2.</b>
                        
                        基本筛选
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.1.3" data-path="jquery/选择器/内容筛选.html">
            
                
                    <a href="../../jquery/选择器/内容筛选.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.1.3.</b>
                        
                        内容筛选
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="4.2" >
            
            <span><b>4.2.</b> 属性、css</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="4.2.1" data-path="jquery/属性、css/CSS.html">
            
                
                    <a href="../../jquery/属性、css/CSS.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.2.1.</b>
                        
                        CSS
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.2.2" data-path="jquery/属性、css/属性.html">
            
                
                    <a href="../../jquery/属性、css/属性.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.2.2.</b>
                        
                        属性
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="4.3" >
            
            <span><b>4.3.</b> 操作</span>
            
            
        </li>
    
        <li class="chapter " data-level="4.4" >
            
            <span><b>4.4.</b> 遍历</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="4.4.1" data-path="jquery/遍历/筛选.html">
            
                
                    <a href="../../jquery/遍历/筛选.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.4.1.</b>
                        
                        筛选
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="4.5" >
            
            <span><b>4.5.</b> 事件</span>
            
            
        </li>
    
        <li class="chapter " data-level="4.6" >
            
            <span><b>4.6.</b> 效果</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="4.6.1" data-path="jquery/效果/基础.html">
            
                
                    <a href="../../jquery/效果/基础.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.6.1.</b>
                        
                        基础
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.6.2" data-path="jquery/效果/自定义.html">
            
                
                    <a href="../../jquery/效果/自定义.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.6.2.</b>
                        
                        自定义
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.6.3" data-path="jquery/效果/渐变.html">
            
                
                    <a href="../../jquery/效果/渐变.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.6.3.</b>
                        
                        渐变
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="4.6.4" data-path="jquery/效果/滑动.html">
            
                
                    <a href="../../jquery/效果/滑动.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>4.6.4.</b>
                        
                        滑动
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="5" >
            
            <span><b>5.</b> 移动端适配</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="5.1" data-path="移动端/1.Viewport移动端.html">
            
                
                    <a href="../../移动端/1.Viewport移动端.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.1.</b>
                        
                        Viewport移动端
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="5.2" data-path="移动端/2.移动端布局种类.html">
            
                
                    <a href="../../移动端/2.移动端布局种类.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.2.</b>
                        
                        移动端布局种类
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="5.3" data-path="移动端/解决fixed定位到浏览器底部但是会挡住一部分内容.html">
            
                
                    <a href="../../移动端/解决fixed定位到浏览器底部但是会挡住一部分内容.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.3.</b>
                        
                        footer挡住一部分内容的问题
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="5.4" data-path="移动端/media适配.html">
            
                
                    <a href="../../移动端/media适配.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.4.</b>
                        
                        media(媒体查询)适配
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="5.5" data-path="移动端/rem布局.html">
            
                
                    <a href="../../移动端/rem布局.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.5.</b>
                        
                        rem布局
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="5.6" data-path="移动端/流式布局.html">
            
                
                    <a href="../../移动端/流式布局.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>5.6.</b>
                        
                        流式布局
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="6" >
            
            <span><b>6.</b> H5游戏</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="6.1" data-path="H5游戏/Egret/配置项目.html">
            
                
                    <a href="../../H5游戏/Egret/配置项目.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.1.</b>
                        
                        配置项目
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.2" data-path="H5游戏/Egret/显示对象.html">
            
                
                    <a href="../../H5游戏/Egret/显示对象.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.2.</b>
                        
                        显示对象
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.3" data-path="H5游戏/Egret/遮罩.html">
            
                
                    <a href="../../H5游戏/Egret/遮罩.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.3.</b>
                        
                        遮罩
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.4" data-path="H5游戏/Egret/屏幕适配.html">
            
                
                    <a href="../../H5游戏/Egret/屏幕适配.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.4.</b>
                        
                        屏幕适配
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.5" data-path="H5游戏/Egret/Event.html">
            
                
                    <a href="../../H5游戏/Egret/Event.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.5.</b>
                        
                        Event
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.6" data-path="H5游戏/Egret/单例模式.html">
            
                
                    <a href="../../H5游戏/Egret/单例模式.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.6.</b>
                        
                        单例模式
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="6.7" data-path="H5游戏/Egret/API_game.html">
            
                
                    <a href="../../H5游戏/Egret/API_game.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>6.7.</b>
                        
                        API
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="7" >
            
            <span><b>7.</b> web工作流</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="7.1" data-path="web工作流/gulp/Gulp.html">
            
                
                    <a href="../../web工作流/gulp/Gulp.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>7.1.</b>
                        
                        gulp
                    </a>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="7.1.1" data-path="web工作流/gulp/初步构建与使用.html">
            
                
                    <a href="../../web工作流/gulp/初步构建与使用.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>7.1.1.</b>
                        
                        初步构建与使用
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="7.1.2" data-path="web工作流/gulp/gulp-API插件.html">
            
                
                    <a href="../../web工作流/gulp/gulp-API插件.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>7.1.2.</b>
                        
                        gulp-API插件
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="8" >
            
            <span><b>8.</b> 常用技巧</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="8.1" >
            
            <span><b>8.1.</b> 溢出处理</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="8.1.1" data-path="常用技巧/溢出处理/图片处理.html">
            
                
                    <a href="../../常用技巧/溢出处理/图片处理.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.1.1.</b>
                        
                        图片处理
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.1.2" data-path="常用技巧/溢出处理/文字溢出处理.html">
            
                
                    <a href="../../常用技巧/溢出处理/文字溢出处理.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.1.2.</b>
                        
                        文字溢出处理
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="8.2" >
            
            <span><b>8.2.</b> 轮播图</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="8.2.1" data-path="常用技巧/轮播图/无方向按钮单方向轮播图.html">
            
                
                    <a href="../../常用技巧/轮播图/无方向按钮单方向轮播图.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.2.1.</b>
                        
                        无方向按钮单方向轮播图
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.2.2" data-path="常用技巧/轮播图/有方向按钮的无缝轮播图.html">
            
                
                    <a href="../../常用技巧/轮播图/有方向按钮的无缝轮播图.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.2.2.</b>
                        
                        有方向按钮的无缝轮播图
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="8.3" data-path="常用技巧/1.常用技巧.html">
            
                
                    <a href="../../常用技巧/1.常用技巧.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.3.</b>
                        
                        常用技巧
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.4" data-path="常用技巧/2.纯CSS画图形.html">
            
                
                    <a href="../../常用技巧/2.纯CSS画图形.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.4.</b>
                        
                        纯CSS画图形
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.5" data-path="常用技巧/3.遮罩层.html">
            
                
                    <a href="../../常用技巧/3.遮罩层.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.5.</b>
                        
                        遮罩层
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.6" data-path="常用技巧/4.git操作.html">
            
                
                    <a href="../../常用技巧/4.git操作.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.6.</b>
                        
                        git操作
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.7" data-path="常用技巧/5.行内元素或行内块元素强制换行.html">
            
                
                    <a href="../../常用技巧/5.行内元素或行内块元素强制换行.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.7.</b>
                        
                        行内元素或行内块元素强制换行
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="8.8" data-path="常用技巧/清楚浮动的方式.html">
            
                
                    <a href="../../常用技巧/清楚浮动的方式.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>8.8.</b>
                        
                        清楚浮动的方式
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="9" >
            
            <span><b>9.</b> 工具使用法</span>
            
            
            <ul class="articles">
                
    
        <li class="chapter " data-level="9.1" data-path="工具使用法/git的使用命令.html">
            
                
                    <a href="../../工具使用法/git的使用命令.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>9.1.</b>
                        
                        git的使用命令
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="9.2" data-path="工具使用法/gitbook的使用.html">
            
                
                    <a href="../../工具使用法/gitbook的使用.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>9.2.</b>
                        
                        gitbook的使用
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="9.3" data-path="工具使用法/Markdown语法.html">
            
                
                    <a href="../../工具使用法/Markdown语法.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>9.3.</b>
                        
                        Markdown语法
                    </a>
            
            
        </li>
    
        <li class="chapter " data-level="9.4" data-path="工具使用法/nodejs的安装.html">
            
                
                    <a href="../../工具使用法/nodejs的安装.html">
                
                        <i class="fa fa-check"></i>
                        
                            <b>9.4.</b>
                        
                        nodejs的安装
                    </a>
            
            
        </li>
    

            </ul>
            
        </li>
    


            
            <li class="divider"></li>
            <li>
                <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
                    Published with GitBook
                </a>
            </li>
            
        </ul>
    </nav>
</div>

    <div class="book-body">
        <div class="body-inner">
            <div class="book-header" role="navigation">
    <!-- Actions Left -->
    

    <!-- Title -->
    <h1>
        <i class="fa fa-circle-o-notch fa-spin"></i>
        <a href="../../" >H5学习笔记</a>
    </h1>
</div>

            <div class="page-wrapper" tabindex="-1" role="main">
                <div class="page-inner">
                
                
                    <section class="normal" id="section-">
                    
                        <h3 id="&#x8BED;&#x53E5;">&#x8BED;&#x53E5;</h3>
<h4 id="1switch-&#x8BED;&#x53E5;">1.switch &#x8BED;&#x53E5;</h4>
<pre><code class="lang-javascript"><span class="hljs-keyword">switch</span>(<span class="hljs-literal">true</span>){
     <span class="hljs-keyword">case</span> tScore&lt;<span class="hljs-number">60</span> &amp;&amp; tScore&gt;=<span class="hljs-number">0</span>:
          alert(<span class="hljs-string">&quot;&#x4E0D;&#x5408;&#x683C;&quot;</span>);
          <span class="hljs-keyword">break</span>;
     <span class="hljs-keyword">case</span> tScore&gt;=<span class="hljs-number">60</span> &amp;&amp; tScore&lt;=<span class="hljs-number">70</span>:
          alert(<span class="hljs-string">&quot;&#x5DEE;&quot;</span>);
          <span class="hljs-keyword">break</span>;
     <span class="hljs-keyword">case</span> tScore&gt;<span class="hljs-number">70</span> &amp;&amp; tScore&lt;<span class="hljs-number">80</span>:
          alert(<span class="hljs-string">&quot;&#x4E2D;&quot;</span>);
          <span class="hljs-keyword">break</span>;
    <span class="hljs-keyword">case</span> tScore&gt;=<span class="hljs-number">80</span> &amp;&amp; tScore&lt;=<span class="hljs-number">95</span>:
          alert(<span class="hljs-string">&quot;&#x826F;&quot;</span>);
          <span class="hljs-keyword">break</span>;
     <span class="hljs-keyword">case</span> tScore&gt;<span class="hljs-number">95</span> &amp;&amp; tScore&lt;=<span class="hljs-number">100</span>:
          alert(<span class="hljs-string">&quot;&#x4F18;&quot;</span>);
          <span class="hljs-keyword">break</span>;
     <span class="hljs-keyword">default</span>:
         alert(<span class="hljs-string">&quot;&#x5206;&#x6570;&#x8303;&#x56F4;&#x662F;0~100,&#x8BF7;&#x91CD;&#x65B0;&#x8F93;&#x5165;!&quot;</span>); 
 }
</code></pre>
<p><strong>&#x8BF4;&#x660E;&#xFF1A;</strong></p>
<pre><code>- switch&#x8BED;&#x53E5;&#x901A;&#x5E38;&#x7528;&#x4E8E;&#x5224;&#x65AD;&#x4E00;&#x4E2A;&#x8868;&#x8FBE;&#x5F0F;&#x53EF;&#x80FD;&#x51FA;&#x73B0;&#x591A;&#x79CD;&#x60C5;&#x51B5;&#x7684;&#x65F6;&#x5019;,&#x5C24;&#x5176;&#x9002;&#x7528;&#x3002;
- &#x53EA;&#x8981;&#x5F53;case&#x8BED;&#x53E5;&#x7684;&#x8868;&#x8FBE;&#x5F0F;&#x7ED3;&#x679C;&#x8DDF;switch&#x8BED;&#x53E5;&#x4E2D;&#x7684;&#x62EC;&#x53F7;&#x5185;&#x7684;&#x8868;&#x8FBE;&#x5F0F;&#x7684;&#x503C;&#x5B8C;&#x5168;&#x76F8;&#x7B49;(&#x503C;&#x548C;&#x7C7B;&#x578B;&#x90FD;&#x5FC5;&#x987B;&#x4E00;&#x81F4;)&#x7684;&#x65F6;&#x5019;,&#x4FBF;&#x4F1A;&#x6267;&#x884C;&#x5BF9;&#x5E94;&#x7684;case&#x8BED;&#x53E5;&#x5757;&#x3002;   
- &#x901A;&#x5E38;&#x6211;&#x4EEC;&#x8FD8;&#x4F1A;&#x5728;&#x6700;&#x540E;&#x52A0;&#x4E0A;&#x4E00;&#x4E2A;default,&#x4EE5;&#x9632;&#x51FA;&#x73B0;&#x4F4D;&#x7F6E;&#x60C5;&#x51B5;
- &#x8BB0;&#x5F97;&#x9664;&#x4E86;&#x6700;&#x540E;&#x4E00;&#x4E2A;&#x5206;&#x652F;&#x4EE5;&#x5916;,&#x90FD;&#x8981;&#x5728;case&#x4EE3;&#x7801;&#x5757;&#x6700;&#x540E;&#x52A0;&#x4E0A;&#x4E00;&#x4E2A;break&#x8BED;&#x53E5;(&#x7ACB;&#x5373;&#x9000;&#x51FA;switch&#x8BED;&#x53E5;&#x5757;,&#x53EF;&#x4EE5;&#x907F;&#x514D;&#x8FC7;&#x591A;&#x7684;&#x65E0;&#x6548;&#x5224;&#x65AD;,&#x52A0;&#x5FEB;&#x7A0B;&#x5E8F;&#x7684;&#x8FD0;&#x884C;&#x901F;&#x5EA6;)
</code></pre><h4 id="2&#x5FAA;&#x73AF;&#x8BED;&#x53E5;">2.&#x5FAA;&#x73AF;&#x8BED;&#x53E5;</h4>
<p>1.while&#x5FAA;&#x73AF;  </p>
<pre><code class="lang-javascript">&lt;script&gt;
    <span class="hljs-keyword">var</span> sum = <span class="hljs-number">0</span>,i = <span class="hljs-number">1</span>;
    <span class="hljs-keyword">while</span>(i&lt;=<span class="hljs-number">100</span>){
        sum += i;
        i++;
    }
    <span class="hljs-built_in">console</span>.log(sum);
<span class="xml"><span class="hljs-tag">&lt;/<span class="hljs-title">script</span>&gt;</span>
</span></code></pre>
<p><strong>&#x5907;&#x6CE8;&#xFF1A;</strong></p>
<pre><code> &#x8981;&#x5728;&#x5FAA;&#x73AF;&#x4F53;&#x91CC;&#x9762;,&#x6709;&#x6539;&#x53D8;&#x5FAA;&#x73AF;&#x5224;&#x65AD;&#x6761;&#x4EF6;&#x7684;&#x8BED;&#x53E5;,&#x5426;&#x5219;&#x53EF;&#x80FD;&#x4F1A;&#x8FDB;&#x5165;&#x6B7B;&#x5FAA;&#x73AF;(&#x7F51;&#x9875;&#x65E0;&#x54CD;&#x5E94;)&#x3002;   
 &#x4F46;&#x662F;&#xFF0C;&#x5728;&#x4EE5;&#x4E0B;&#x60C5;&#x51B5;&#xFF0C;&#x6211;&#x4EEC;&#x4F1A;&#x7528;&#x5230;&#x6B7B;&#x5FAA;&#x73AF;&#xFF0C;   
 &#x4F8B;&#x5982;&#xFF1A;&#x7B49;&#x5F85;&#x54CD;&#x5E94;,&#x7B49;&#x5F85;&#x670D;&#x52A1;&#x3002;
</code></pre><hr>
<p>2.for&#x5FAA;&#x73AF;&#x8BED;&#x53E5;   </p>
<pre><code class="lang-html">for(&#x5B9A;&#x4E49;&#x5FAA;&#x73AF;&#x5F00;&#x59CB;&#x503C;;&#x5FAA;&#x73AF;&#x5224;&#x65AD;&#x6761;&#x4EF6;;&#x5FAA;&#x73AF;&#x4E2D;&#x505A;&#x7684;&#x4E8B;&#x60C5;){

}


- &#x5199;&#x6CD5;&#x4E00;&#xFF1A;
var num=1;
for(var i=1;i&lt;5;num*=i,i++){
}
console.log(num);


- &#x5199;&#x6CD5;&#x4E8C;&#xFF1A;
&lt;script type=&quot;text/javascript&quot;&gt;
    var num=1;
    for(var i=1;i&lt;5;i++){
        num*=i;
    }
    console.log(num);
&lt;/script&gt;
</code></pre>
<p><strong>&#x4E5D;&#x4E5D;&#x4E58;&#x6CD5;&#x8868;</strong></p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> xy;
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;table&gt;&quot;</span>);                  <span class="hljs-comment">//&#x6784;&#x6210;&#x8868;&#x683C;</span>
<span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> i = <span class="hljs-number">1</span>;i&lt;<span class="hljs-number">10</span>;i++){
    <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;tr&gt;&quot;</span>);                 <span class="hljs-comment">//&#x63D2;&#x5165;&#x884C;</span>
    <span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> j = <span class="hljs-number">1</span>;j&lt;=i;j++){
        xy = i*j;
        <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;td&gt;&quot;</span>+i+<span class="hljs-string">&quot;*&quot;</span>+j+<span class="hljs-string">&quot;=&quot;</span>+xy+<span class="hljs-string">&quot;&lt;/td&gt;&quot;</span>);
    }
    <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/tr&gt;&quot;</span>);               <span class="hljs-comment">//&#x63D2;&#x5165;&#x884C;</span>
}
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/table&gt;&quot;</span>);                <span class="hljs-comment">//&#x6784;&#x6210;&#x8868;&#x683C;</span>
</code></pre>
<p><strong>&#x6700;&#x7EC8;&#x6548;&#x679C;&#xFF1A;</strong><br><img src="../../img/javascript/&#x4E5D;&#x4E5D;&#x4E58;&#x6CD5;&#x8868;.jpg" alt="&#x4E5D;&#x4E5D;&#x4E58;&#x6CD5;&#x8868;"></p>
<p><strong>&#x53CD;&#x4E5D;&#x4E5D;&#x4E58;&#x6CD5;&#x8868;</strong></p>
<ul>
<li><p>&#x65B9;&#x6CD5;&#x4E00;&#xFF1A;</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> xy;
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;table&gt;&quot;</span>);
<span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> i = <span class="hljs-number">1</span>;i&lt;<span class="hljs-number">10</span>;i++){
  <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;tr&gt;&quot;</span>);

  <span class="hljs-comment">//&#x8F93;&#x5165;&#x7A7A;&#x767D;&#x7684;td</span>
  <span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> m = <span class="hljs-number">1</span>;m&lt;<span class="hljs-number">10</span>-i;m++){
      <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;td&gt;&lt;/td&gt;&quot;</span>);
  }
  <span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> j = <span class="hljs-number">1</span>;j&lt;=i;j++){
      xy = i*j;
      <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;td&gt;&quot;</span>+i+<span class="hljs-string">&quot;*&quot;</span>+j+<span class="hljs-string">&quot;=&quot;</span>+xy+<span class="hljs-string">&quot;&lt;/td&gt;&quot;</span>);
  }
  <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/tr&gt;&quot;</span>);
}
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/table&gt;&quot;</span>);
</code></pre>
</li>
<li><p>&#x65B9;&#x6CD5;&#x4E8C;&#xFF1A;</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> xy;
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;table&gt;&quot;</span>);
<span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> i = <span class="hljs-number">1</span>;i&lt;<span class="hljs-number">10</span>;i++){
  <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;tr&gt;&quot;</span>);

  <span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> j = <span class="hljs-number">9</span>;j&gt;<span class="hljs-number">0</span>;j--){
      <span class="hljs-comment">//</span>
      <span class="hljs-keyword">if</span>(j&lt;=i){
          xy = i*j;
          <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;td&gt;&quot;</span>+i+<span class="hljs-string">&quot;*&quot;</span>+j+<span class="hljs-string">&quot;=&quot;</span>+xy+<span class="hljs-string">&quot;&lt;/td&gt;&quot;</span>);
      }<span class="hljs-keyword">else</span>{
          <span class="hljs-comment">//&#x8F93;&#x51FA;&#x7A7A;&#x767D;td</span>
          <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;td&gt;&lt;/td&gt;&quot;</span>);
      }
  }
  <span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/tr&gt;&quot;</span>);
}
<span class="hljs-built_in">document</span>.write(<span class="hljs-string">&quot;&lt;/table&gt;&quot;</span>);
</code></pre>
</li>
</ul>
<hr>
<p><strong>break</strong>   </p>
<ul>
<li>&#x57FA;&#x7840;&#x7528;&#x6CD5;:<pre><code class="lang-javascript"><span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> i = <span class="hljs-number">0</span>;i&lt;=<span class="hljs-number">100</span>;i++){
  <span class="hljs-comment">//</span>
  <span class="hljs-keyword">if</span>(i&gt;=<span class="hljs-number">50</span>){
      <span class="hljs-keyword">break</span>;       <span class="hljs-comment">//&#x8DF3;&#x51FA;&#x6574;&#x4E2A;&#x5FAA;&#x73AF;</span>
  }
  <span class="hljs-built_in">console</span>.log(i);
}
</code></pre>
</li>
<li><p>&#x5D4C;&#x5957;&#x5FAA;&#x73AF;&#x7684;&#x65F6;&#x5019;,break&#x662F;&#x9000;&#x51FA;&#x6700;&#x63A5;&#x8FD1;&#x5B83;&#x7684;&#x5FAA;&#x73AF;&#x4F53;  </p>
<pre><code>for(var i = i;i&lt;=3;i++){
  for(){
     if(j&gt;=2){
         break;       //&#x7ACB;&#x5373;&#x8DF3;&#x51FA;&#x6700;&#x5185;&#x5C42;&#x7684;&#x5FAA;&#x73AF;
     }
  }
  console.log(&quot;&#x5185;&#x5C42;&#x5FAA;&#x73AF;:&quot;+j);
}
</code></pre><p><strong>&#x8BF4;&#x660E;&#xFF1A;</strong>&#x53EA;&#x5FAA;&#x73AF;&#x4E86;6&#x6B21;&#xFF0C;&#x5206;&#x522B;&#x662F;&#x5916;3&#x6B21;,&#x5185;3&#x6B21; </p>
</li>
<li><p>&#x5F53;&#x6211;&#x4EEC;&#x8981;&#x9000;&#x51FA;&#x591A;&#x6307;&#x5B9A;&#x5FAA;&#x73AF;&#x4F53;&#x7684;&#x65F6;&#x5019;,&#x53EF;&#x4EE5;&#x6307;&#x5B9A;&#x5FAA;&#x73AF;&#x4F53;&#x7684;&#x540D;&#x79F0;(&#x5373;&#x5229;&#x7528;Label&#x8BED;&#x53E5;)</p>
<pre><code>bgg:for(var )
</code></pre><p>&#x53EA;&#x5FAA;&#x73AF;&#x4E86;2&#x6B21;,&#x5206;&#x522B;&#x662F;&#x5916;1&#x6B21;,&#x5185;1&#x6B21;</p>
</li>
</ul>
<hr>
<p>3.for-in<br>for-in   &#x4E13;&#x95E8;&#x7528;&#x4E8E;&#x5FAA;&#x73AF;&#x5BF9;&#x8C61;,&#x5F53;&#x7136;&#x4E5F;&#x53EF;&#x4EE5;&#x5FAA;&#x73AF;&#x6570;&#x7EC4;</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> obj = {
  <span class="hljs-comment">// &#x952E;&#x540D; &#xFF1A; &#x952E;&#x503C;</span>
    <span class="hljs-string">&quot;name&quot;</span>:<span class="hljs-string">&quot;xiaoming&quot;</span>,
    <span class="hljs-string">&quot;age&quot;</span>:<span class="hljs-number">20</span>,
    <span class="hljs-string">&quot;job&quot;</span>:<span class="hljs-string">&quot;&#x7A0B;&#x5E8F;&#x5458;&quot;</span>
}

<span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> k <span class="hljs-keyword">in</span> obj){
    <span class="hljs-built_in">console</span>.log(k);          <span class="hljs-comment">//&#x952E;&#x540D;</span>
    <span class="hljs-built_in">console</span>.log(obj[k]);     <span class="hljs-comment">//&#x952E;&#x503C;</span>
}
</code></pre>
<p><strong>&#x6CE8;&#x660E;&#xFF1A;</strong>   </p>
<pre><code>Safari 3 &#x4EE5; &#x524D; &#x7248; &#x672C; &#x7684; for-in &#x8BED; &#x53E5; &#x4E2D; &#x5B58; &#x5728; &#x4E00; &#x4E2A; bug&#xFF0C; &#x8BE5; bug &#x4F1A; &#x5BFC; &#x81F4; &#x67D0; &#x4E9B; &#x5C5E; &#x6027; &#x88AB; &#x8FD4; &#x56DE; &#x4E24; &#x6B21;&#x3002;
</code></pre><p><strong>&#x793A;&#x4F8B;(json&#x6570;&#x636E;)&#xFF1A;</strong></p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> json = {
    a:<span class="hljs-number">5</span> ,
    b:<span class="hljs-number">12</span>,
    c:<span class="hljs-number">15</span>
};

<span class="hljs-comment">//&#x904D;&#x5386;json&#x7684;&#x6570;&#x636E;</span>
<span class="hljs-keyword">for</span>(<span class="hljs-keyword">var</span> j <span class="hljs-keyword">in</span> json){
    alert(<span class="hljs-string">&quot;&#x7B2C;&quot;</span>+j+<span class="hljs-string">&quot;&#x6570;&#x5B57;&#x662F;&#xFF1A;&quot;</span>+json[j]);
}


<span class="hljs-comment">//json  &#x5E95;&#x6570;&#x4E3A;&#x5B57;&#x7B26;  &#xFF0C;  array  &#x5E95;&#x6570;&#x4E3A;&#x6570;&#x5B57;</span>
<span class="hljs-comment">//&#x83B7;&#x53D6;&#x5355;&#x4E2A;&#x6570;&#x636E;</span>
alert(json[<span class="hljs-string">&apos;a&apos;</span>]);         <span class="hljs-comment">//&#x5E95;&#x6570;&#x4E3A;&#x201C;a&#x201D; &#x7684;&#x6570;&#x636E;</span>
</code></pre>
<hr>
<p>4.do-while&#x8BED;&#x53E5;   </p>
<pre><code>- &#x662F;&#x4E00;&#x79CD;&#x540E;&#x6D4B;&#x8BD5;&#x5FAA;&#x73AF;&#x8BED;&#x53E5;
- &#x5373;&#x5728;&#x6267;&#x884C;&#x201C;&#x5FAA;&#x73AF;&#x4F53;&#x79CD;&#x7684;&#x4EE3;&#x7801;&#x201D;&#x4E4B;&#x540E;&#xFF0C;&#x624D;&#x4F1A;&#x6D4B;&#x8BD5;&#x51FA;&#x53E3;&#x6761;&#x4EF6;
- &#x5373;&#x6B64;&#x5FAA;&#x73AF;&#xFF0C;&#x5FAA;&#x73AF;&#x4EE3;&#x7801;&#x81F3;&#x5C11;&#x6267;&#x884C;&#x4E00;&#x6B21;(&#x5373;&#x65E0;&#x8BBA;&#x662F;&#x5426;&#x6EE1;&#x8DB3;&#x6761;&#x4EF6;,&#x90FD;&#x81F3;&#x5C11;&#x6267;&#x884C;&#x4E00;&#x6B21;)
</code></pre><p><strong>&#x8BED;&#x6CD5;</strong></p>
<pre><code class="lang-javascript"><span class="hljs-keyword">do</span>{
   statement           <span class="hljs-comment">//&#x5FAA;&#x73AF;&#x4F53;</span>
}<span class="hljs-keyword">while</span>(expression)     <span class="hljs-comment">//&#x5FAA;&#x73AF;&#x5224;&#x65AD;</span>
</code></pre>
<p><strong>&#x793A;&#x4F8B;:</strong>  </p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> i = <span class="hljs-number">0</span>;
<span class="hljs-keyword">do</span>{
    i+=<span class="hljs-number">2</span>;
}<span class="hljs-keyword">while</span>(i &lt; <span class="hljs-number">10</span>);
alert(i);
</code></pre>
<p><strong>&#x6CE8;&#x660E;&#xFF1A;</strong></p>
<pre><code>&#x50CF; do-while &#x8FD9; &#x79CD; &#x540E; &#x6D4B; &#x8BD5; &#x5FAA; &#x73AF; &#x8BED; &#x53E5; &#x6700; &#x5E38; &#x7528; &#x4E8E; &#x5FAA; &#x73AF; &#x4F53; &#x4E2D; &#x7684; &#x4EE3; &#x7801; &#x81F3; &#x5C11; &#x8981; &#x88AB; &#x6267; &#x884C; &#x4E00; &#x6B21; &#x7684; &#x60C5; &#x5F62;&#x3002;
</code></pre><h4 id="3label&#x8BED;&#x53E5;">3.Label&#x8BED;&#x53E5;</h4>
<pre><code>Label&#x8BED;&#x53E5;&#x53EF;&#x4EE5;&#x5728;&#x4EE3;&#x7801;&#x4E2D;&#x6DFB;&#x52A0;&#x6807;&#x7B7E;,&#x4EE5;&#x4FBF;&#x5C06;&#x6765;&#x4F7F;&#x7528;&#x3002;
</code></pre><p><strong>&#x8BED;&#x6CD5;&#xFF1A;</strong></p>
<pre><code>label : statement 

Label : &#x4EFB;&#x4F55;&#x4E0D;&#x662F;&#x4FDD;&#x7559;&#x5B57;&#x7684;JavaScript&#x6807;&#x8BC6;&#x7B26; (&#x5C06;&#x7531;break&#x3001;continue&#x6765;&#x5F15;&#x7528;)

statement : &#x8BED;&#x53E5;&#x3002;break&#x53EF;&#x4EE5;&#x4E0E;&#x4EFB;&#x4F55;&#x6807;&#x8BB0;&#x7684;&#x8BED;&#x53E5;&#x4E00;&#x8D77;&#x4F7F;&#x7528;&#xFF0C;&#x5E76;&#x4E14;&#x53EF;&#x4EE5;&#x7EE7;&#x7EED;&#x4F7F;&#x7528;&#x5E26;&#x6709;&#x6807;&#x8BB0;&#x8BED;&#x53E5;&#x7684;&#x5FAA;&#x73AF;&#x8BED;&#x53E5;&#x3002;
</code></pre><p><strong>&#x793A;&#x4F8B;&#xFF1A;</strong>  </p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> i, j;

loop1:
<span class="hljs-keyword">for</span> (i = <span class="hljs-number">0</span>; i &lt; <span class="hljs-number">3</span>; i++) {           <span class="hljs-comment">//The first for statement is labeled &quot;loop1&quot;</span>
   loop2:
   <span class="hljs-keyword">for</span> (j = <span class="hljs-number">0</span>; j &lt; <span class="hljs-number">3</span>; j++) {        <span class="hljs-comment">//The second for statement is labeled &quot;loop2&quot;</span>
      <span class="hljs-keyword">if</span> (i === <span class="hljs-number">1</span> &amp;&amp; j === <span class="hljs-number">1</span>) {
         <span class="hljs-keyword">continue</span> loop1;
      }
      <span class="hljs-built_in">console</span>.log(<span class="hljs-string">&apos;i = &apos;</span> + i + <span class="hljs-string">&apos;, j = &apos;</span> + j);
   }
}
</code></pre>
<p><strong>&#x8FD0;&#x884C;&#x7ED3;&#x679C;&#x5982;&#x4E0B;:</strong></p>
<pre><code>    //break
    i = 0, j = 0
    i = 0, j = 1
    i = 0, j = 2
    i = 1, j = 0
    i = 2, j = 0
    i = 2, j = 1
    i = 2, j = 2

    //continue
</code></pre><h4 id="4with&#x8BED;&#x53E5;">4.with&#x8BED;&#x53E5;</h4>
<pre><code>&#x4F5C;&#x7528;&#xFF1A; &#x5C06;&#x4EE3;&#x7801;&#x7684;&#x4F5C;&#x7528;&#x57DF;&#x8BBE;&#x7F6E;&#x5230;&#x4E00;&#x4E2A;&#x7279;&#x5B9A;&#x7684;&#x5BF9;&#x8C61;&#x4E2D;&#x3002;  
&#x8BED;&#x6CD5;&#xFF1A; with (expresssion)  statement;
</code></pre><p><strong>&#x793A;&#x4F8B;&#x4EE3;&#x7801;&#xFF1A;</strong></p>
<ul>
<li><p>&#x6307;&#x5B9A;Math&#x5BF9;&#x8C61;&#x662F;&#x9ED8;&#x8BA4;&#x5BF9;&#x8C61;
```javascript
  var a, x, y;
  var r = 10;</p>
<p>  //&#x6CA1;&#x6709;&#x7528;with&#x8BED;&#x53E5;
  a = Math.PI <em> r </em> r;
  x = r <em> Math.cos(Math.PI);
  y = r </em> Math.sin(Math.PI / 2);</p>
</li>
</ul>
<pre><code>//&#x4F7F;&#x7528;with&#x8BED;&#x53E5;
with (Math) {
  a = PI * r * r;
  x = r * cos(PI);
  y = r * sin(PI / 2);
}
</code></pre><pre><code>
**&#x6CE8;&#x660E;&#xFF1A;**
</code></pre><p>&#x7531; &#x4E8E; &#x5927; &#x91CF; &#x4F7F; &#x7528; with &#x8BED; &#x53E5; &#x4F1A; &#x5BFC; &#x81F4; &#x6027; &#x80FD; &#x4E0B; &#x964D;&#xFF0C; &#x540C; &#x65F6; &#x4E5F; &#x4F1A; &#x7ED9; &#x8C03; &#x8BD5; &#x4EE3; &#x7801; &#x9020; &#x6210; &#x56F0; &#x96BE;&#xFF0C;<br>&#x56E0; &#x6B64; &#x5728; &#x5F00; &#x53D1; &#x5927; &#x578B; &#x5E94; &#x7528; &#x7A0B; &#x5E8F; &#x65F6;&#xFF0C; &#x4E0D; &#x5EFA; &#x8BAE; &#x4F7F; &#x7528; with &#x8BED; &#x53E5;&#x3002;</p>
<pre><code>

####5.return

&gt;&#x7EC8;&#x6B62;&#x51FD;&#x6570;&#x7684;&#x6267;&#x884C;&#xFF0C;&#x5E76;&#x8FD4;&#x56DE;&#x4E00;&#x4E2A;&#x6307;&#x5B9A;&#x7684;&#x503C;&#x7ED9;&#x51FD;&#x6570;&#x8C03;&#x7528;&#x8005;&#x3002;





###6.for...of statement (ES6)
</code></pre><p>&#x4E0E; for...in &#x5FAA;&#x73AF;&#x904D;&#x5386;&#x7684;&#x7ED3;&#x679C;&#x662F;&#x6570;&#x7EC4;&#x5143;&#x7D20;&#x7684;&#x4E0B;&#x6807;&#x4E0D;&#x540C;&#x7684;&#x662F;&#xFF0C;<br>for...of &#x904D;&#x5386;&#x7684;&#x7ED3;&#x679C;&#x662F;&#x5143;&#x7D20;&#x7684;&#x503C;&#xFF1A;</p>
<pre><code>
**&#x4EE3;&#x7801;&#x793A;&#x4F8B;**
```javascript
let arr = [3, 5, 7];
arr.foo = &quot;hello&quot;;

for (let i in arr) {
   console.log(i); // logs &quot;0&quot;, &quot;1&quot;, &quot;2&quot;, &quot;foo&quot;
}

for (let i of arr) {
   console.log(i); // logs &quot;3&quot;, &quot;5&quot;, &quot;7&quot; // &#x6CE8;&#x610F;&#x8FD9;&#x91CC;&#x6CA1;&#x6709; hello
}
</code></pre>
                    
                    </section>
                
                
                </div>
            </div>
        </div>

        
        <a href="../../javascript/Javascript基础/运算符.html" class="navigation navigation-prev " aria-label="Previous page: 运算符"><i class="fa fa-angle-left"></i></a>
        
        
        <a href="../../javascript/Javascript基础/系统自带的常用函数.html" class="navigation navigation-next " aria-label="Next page: 系统自带的常用函数"><i class="fa fa-angle-right"></i></a>
        
    </div>
</div>

        
<script src="../../gitbook/app.js"></script>

    
    <script src="../../gitbook/plugins/gitbook-plugin-search/lunr.min.js"></script>
    

    
    <script src="../../gitbook/plugins/gitbook-plugin-search/search.js"></script>
    

    
    <script src="../../gitbook/plugins/gitbook-plugin-sharing/buttons.js"></script>
    

    
    <script src="../../gitbook/plugins/gitbook-plugin-fontsettings/buttons.js"></script>
    

<script>
require(["gitbook"], function(gitbook) {
    var config = {"highlight":{},"search":{"maxIndexSize":1000000},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2}};
    gitbook.start(config);
});
</script>

        
    </body>
    
</html>
